home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
EnigmA Amiga Run 1995 October
/
EnigmA AMIGA RUN 01 (1995)(G.R. Edizioni)(IT)[!][issue 1995-10][Aminet 7].iso
/
Aminet
/
util
/
misc
/
cookies.lha
/
Cookie
/
README
< prev
next >
Wrap
Text File
|
1991-01-14
|
2KB
|
43 lines
The second release of Karl's fortune cookie program, with cookies... 12-Jan-89
-------------------------------------------------------------------------------
Actually, the cookie file contains fortune cookies, sayings, jokes, aphorisms,
quotes and so on. Those likely to be offended by words and ideas that are
alien to them are asked to not read the cookie file.
The code and cookies are released into the public domain without restriction.
I ask that you retain my name in the source code if you redistribute this stuff,
and that you redistribute source along with binaries.
No warranties are expressed or implied -- this is free code. We do not have
a contract.
The code is written for System V but the only area of incompatibility should be
the rand() function. Only minor hacking should be necessary to port to BSD,
for example.
To use, unshar this archive and do a 'make' to compile 'cookie' and 'cookhash'.
Collect the six parts of the cookie file, strip off the headers and trailers,
and 'cat' them (in proper order) into one file. The include file "cookie.h"
defines the location of the cookie file as being "/usr/local/lib/sayings".
If you want to put it elsewhere, change cookie.h and rebuild 'cookie'.
Cookie needs a hash file for the cookie file, by default called
"/usr/local/lib/sayhash". This is created by the 'cookhash' program.
Cookhash is simply a filter that reads a cookie file in as stdin and writes
a cookie hash file to stdout. (Cookies are delineated in the cookie file
by a line containing two percent signs and nothing else.) Thus, if you've
moved the cookie file to /usr/local/lib, 'cd' there and do a
"cookhash <sayings >sayhash" to create the hash file.
After that, 'cookie' should produce a cookie. Cookie can also be executed
with two arguments, the name of a cookie file followed by the name of
its hash file.
If you find quotes in the file that are unattributed and you know the
attributions, please mail them to karl@sugar.uu.net or uunet!sugar!karl
Regards,
karl @ The Hacker's Haven, Missouri City, Texas -- 12-Jan-89